<template>
<div>
  <!-- 面包屑导航区   -->
  <el-breadcrumb separator-class="el-icon-arrow-right">
    <el-breadcrumb-item :to="{ path: '/Ad_home' }">首页</el-breadcrumb-item>
    <el-breadcrumb-item>教员信息</el-breadcrumb-item>
  </el-breadcrumb>
  <!--  卡片视图区  -->
  <el-card class="box-card">
    <el-row :gutter="20">
      <el-col :span="7">
        <el-input placeholder="请输入需要查询的用户姓名" clearable>
          <el-button slot="append" icon="el-icon-search"></el-button>
        </el-input>
      </el-col>
      <el-col :span="4">
        <el-button type="primary" @click="addDialogVisible = true"> 添加用户</el-button>
      </el-col>
    </el-row>
    <!--  用户列表区    -->
    <el-table  border stripe :cell-style="{'text-align':'center'}" :header-cell-style="{'text-align':'center'}">
      <el-table-column type="index" width="100px"></el-table-column>
      <el-table-column label="教师姓名" prop="professionalName" width="100px"></el-table-column>
      <el-table-column label="教师账号" prop="subjectName" width="100px"></el-table-column>
      <el-table-column label="教师密码" prop="subjectName" width="100px"></el-table-column>
      <el-table-column label="头像" prop="subjectName"></el-table-column>
      <el-table-column label="学校" prop="subjectName"></el-table-column>
      <el-table-column label="专业" prop="subjectName"></el-table-column>
      <el-table-column label="年级" prop="subjectName"></el-table-column>
      <el-table-column label="联系方式" prop="subjectName" width="100px"></el-table-column>
      <el-table-column label="地址" prop="subjectName"></el-table-column>
      <el-table-column label="性别" prop="subjectName"></el-table-column>
      <el-table-column label="简介" prop="subjectName"></el-table-column>
      <el-table-column label="照片" prop="subjectName"></el-table-column>
      <el-table-column label="价格" prop="subjectName"></el-table-column>
      <el-table-column label="空闲时间" prop="subjectName" width="100px"></el-table-column>
      <el-table-column label="操作" prop="" width="160px">
        <template>
          <el-tooltip class="item" effect="dark" content="删除科目" placement="top" :enterable="false">
            <el-button type="danger" icon="el-icon-delete" size="small"></el-button>
          </el-tooltip>
        </template>
      </el-table-column>
    </el-table>
    <!--   分页区域    -->
    <el-pagination
        @size-change="handleSizeChange"
        @current-change="handleCurrentChange"
        :current-page="queryInfo.current"
        :page-sizes="[1, 2, 5, 10]"
        :page-size="queryInfo.size"
        layout="total, sizes, prev, pager, next, jumper"
        :total="total">
    </el-pagination>

  </el-card>
</div>
</template>

<script>
export default {
  name: "M_teacher",
  data(){
    return{
      queryInfo:{
        professional:'',
        current:1,
        size:5,
      },
      total:0
    }
  },
  methods:{
    //监听pageSize改变的事件
    handleSizeChange(newSize){
      this.queryInfo.size = newSize
    },
    handleCurrentChange(newPage){
      this.queryInfo.current = newPage
    },
  }
}
</script>

<style scoped>
.el-table{
  margin-top: 25px;
  font-size: 15px;
}
.el-pagination{
  margin-top: 15px;
}
</style>
